

package com.hazelcast.internal.config;

import com.hazelcast.config.CardinalityEstimatorConfig;
import com.hazelcast.config.MergePolicyConfig;

public class CardinalityEstimatorConfigReadOnly extends CardinalityEstimatorConfig {

    public CardinalityEstimatorConfigReadOnly(CardinalityEstimatorConfig config) {
        super(config);
    }

    @Override
    public CardinalityEstimatorConfig setName(String name) {
        throw new UnsupportedOperationException("This config is read-only cardinality estimator: " + getName());
    }

    @Override
    public CardinalityEstimatorConfig setBackupCount(int backupCount) {
        throw new UnsupportedOperationException("This config is read-only cardinality estimator: " + getName());
    }

    @Override
    public CardinalityEstimatorConfig setAsyncBackupCount(int asyncBackupCount) {
        throw new UnsupportedOperationException("This config is read-only cardinality estimator: " + getName());
    }

    @Override
    public CardinalityEstimatorConfig setSplitBrainProtectionName(String splitBrainProtectionName) {
        throw new UnsupportedOperationException("This config is read-only cardinality estimator: " + getName());
    }

    @Override
    public CardinalityEstimatorConfig setMergePolicyConfig(MergePolicyConfig mergePolicyConfig) {
        throw new UnsupportedOperationException("This config is read-only cardinality estimator: " + getName());
    }
}
